﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Diagnostics;
using System.Linq;
using System.ServiceModel;
using System.ServiceProcess;
using System.Text;

namespace RampWindowsService
{
    public partial class LoadTestRampService : ServiceBase
    {
        public ServiceHost serviceHost = null;

        public LoadTestRampService()
        {
            InitializeComponent();
            if (!System.Diagnostics.EventLog.SourceExists("LoadTestRampService"))
            {
                System.Diagnostics.EventLog.CreateEventSource("LoadTestRampService", "LoadTestRampServiceLog");
            }
            loadTestEventLog.Source = "LoadTestRampService";
            loadTestEventLog.Log = "LoadTestRampServiceLog";
        }

        protected override void OnStart(string[] args)
        {
            loadTestEventLog.WriteEntry("Attempting to start: LoadTestRampService");

            loadTestEventLog.WriteEntry("Started: LoadTestRampService");
        }

        protected override void OnStop()
        {
            loadTestEventLog.WriteEntry("Attempting to stop: LoadTestRampService");

            loadTestEventLog.WriteEntry("Stopped: LoadTestRampService");
        }
    }
}
